import org.springframework.stereotype.Service;
import javax.annotation.Resource;

@Service
public class LoginService {
    @Resource
    private UserMapper userMapper;

    public boolean login(String username, String password) {
        User user = userMapper.getUserByNama(username);
        if (user!= null && user.getPassword().equals(password)) {
            return true;
        }
        return false;
    }
}
